package com.sr.service.impl;

import com.sr.dao.LogDao;
import com.sr.ibase.impl.BaseServiceImpl;
import com.sr.pojo.SysLog;
import com.sr.service.ILogService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author xiaochi
 * @date 2022/5/3 20:36
 * @desc LogServiceImpl
 */
@Service
@RequiredArgsConstructor(onConstructor = @__)
public class LogServiceImpl extends BaseServiceImpl<SysLog> implements ILogService {

    private final LogDao logDao;

    /**
     * 删除日志(批量/单条)
     * @param logIds
     * @return
     */
    @Override
    public int deletedLog(List<String> logIds) {
        return logDao.batchDeletedLog(logIds);
    }

    /**
     * 清空日志
     * @return
     */
    @Override
    public int cleanLog() {
        return logDao.cleanLog();
    }
}
